package com.zb.internetSpider.gui.asiderPanel;

import java.awt.BorderLayout;
import java.awt.Color;
import java.awt.Font;
import java.awt.Label;
import java.util.ArrayList;

import javax.swing.DefaultListModel;
import javax.swing.JList;
import javax.swing.JScrollPane;
import javax.swing.JTextArea;
import javax.swing.JTree;

import org.springframework.stereotype.Component;

import com.zb.internetSpider.gui.SpiderContainer;
import com.zb.internetSpider.gui.mainPanel.AbstractSpiderMainPanel;
import com.zb.internetSpider.gui.splitPanel.AbstractSpiderSplitPane;
import com.zb.internetSpider.gui.tree.AbstractSpiderTree;
import com.zb.internetSpider.utils.CommonUtils;

@Component
public class DefaultSpiderAsiderPanel extends AbstractSpiderAsiderPanel {	

	/**
	 * 
	 */
	private static final long serialVersionUID = 7235997206206946539L;
	
	
	public DefaultSpiderAsiderPanel() {
		// TODO Auto-generated constructor stub		
	}


	@Override
	public void setFont(Font font, Color color) {
		// TODO Auto-generated method stub
		
	}

	@Override
	public void addSpiderContainer(SpiderContainer... containers) {
		// TODO Auto-generated method stub
		
		if(this.containers == null){
			this.containers = new ArrayList<SpiderContainer>();
		}
		
		for(SpiderContainer sContainer: containers) {
			this.containers.add(sContainer);
			if(sContainer instanceof AbstractSpiderTree){
				/**
				 * 添加菜单树
				 */								
				super.add((AbstractSpiderTree)sContainer, BorderLayout.CENTER);
			}
		}
		
	}

}
